This invention relates to state machines and in particular to state machines for use in DRAM controllers.
Original equipment manufacturers often design system components with many options to differentiate their products from other products made with the same chip set. Briefly summarized, options are the ability to support in an optimized fashion alternate cycle types or operating speeds. Each option requires that the component controller execute a unique series of states to generate the timing signals required to implement that option.
The practice of adding options to customize a device is particularly evident in the design of dynamic random access memory (DRAM) controllers. FIG. 1 shows a typical system architecture having a microprocessor 10, a DRAM 4 and a DRAM controller 5. Microprocessor 10 asserts an address request signal to controller 5 to begin a memory access. A state machine within controller 5 then transitions through the states necessary to issue the appropriate timing signals to DRAM 4 to perform the memory access. When DRAM 4 completes the memory access, controller 5 asserts a ready signal to microprocessor 10. Microprocessor 10 samples the ready signal on a given edge of the system clock and when the ready signal is detected reads the data retrieved from DRAM 4.
Memory access can occur using many different types of cycles such as page hit, page miss, RAS/CAS and RAS high. These cycles are diagrammed in FIG. 2. Memory access begins with the row address strobe (RAS) 11 going low to activate the memory row line, followed by the column address strobe (CAS) going low to activate a particular column within that row. The memory access cycle ends when CAS goes high. In the page hit cycle, the row address is assumed to be the same as the previous row address and there is no need to reassert RAS in this cycle type.
As can be seen from FIG. 2 each memory cycle type requires a different amount of time for completion. Ideally, each one of the memory access cycle types is individually optimized to provide the maximum operating speed for all cycles. For optimization of each cycle type to occur, the controller state machine must issue the strobe timing signals at different periods of time for each cycle. The state machine of the DRAM controller must thus transition through a different sequence of states to implement each cycle type.
In addition to the many memory access cycle types, DRAMs have many different operating speeds. Two common DRAM operating speeds are 80 and 100 nanoseconds. Within each different speed class, individual DRAM manufacturers specify their own unique timing parameters for each type of cycle. For example, the timing parameters of manufacturer A may require that a page hit cycle CAS be five clock cycles in duration, while the timing parameters of manufacturer B require CAS be six clock cycles in duration. Thus, there exists a plethora of DRAM optimization parameters which can be included as various timing options. One set of timing options is needed on the controller chip just to support multiple cycle types. Another set of timing options must be included, if the DRAM controller is designed to support more than one manufacturer's DRAM.
Typical chip set designs employ DRAM state machines having many states to allow for all the options. Because the microprocessor samples the ready signal on a given edge of the system clock, the states in the state machine must be explicitly synchronized, or aligned with, the correct phase of the system clock, SCLK. Therefore, options must insert an even number of states in the state machine to ensure that the state machine is aligned with SCLK at the completion of the memory cycle. Ensuring an even number of states often requires the addition of unnecessary idle states. Optionally, systems designers can refrain from combining options in such a way that an odd number of states occur. In this way, certain combinations of options become illegal.
The sheer number of options and the restrictions on implementing them, make controller state machine design complex and difficult. The need to insert idle states to ensure an even number of states greatly increases the number of states which must be incorporated into the controller state machine. In addition, options may be inadvertently combined in an illegal manner unbeknownst to the system user. These two facts complicate the debugging process, increase controller chip costs and delay delivery of new systems to the market place.